/* styles.css */
body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
    margin: 0;
    padding: 0;
}

.file-manager {
    max-width: 1200px;
    margin: auto;
    border: 1px solid #ddd;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.toolbar {
    display: flex;
    gap: 10px;
    padding: 6px;
    background-color: #f0f0f0;
    color: white;
    position: relative;
    max-width: 1200px;
    top: 0;
    z-index: 1000;
}

.toolbar button {
    padding: 10px 15px;
    border: none;
    border-radius: 5px;
    background-color: #a0a0a0;
    color: white;
    cursor: pointer;
    font-size: 16px;
}

.toolbar button:hover {
    background-color: #808080;
}

.toolbar button img.icon {
    width: 16px;
    height: 16px;
    margin-right: 5px;
    vertical-align: middle;
}

.breadcrumb {
    margin-top: 0px; /* To ensure breadcrumb is not hidden under the fixed toolbar */
    padding: 10px;
    font-size: 18px;
}

.breadcrumb a {
    text-decoration: none;
    color: #007bff;
    margin-right: 5px;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.file-list {
    margin-top: 0px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: auto;
    max-height: calc(100vh - 140px); /* Adjust height to ensure it fits within the viewport */
}

#file-table {
    width: 100%;
    border-collapse: collapse;
}

#file-table th, #file-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

#file-table th {
    background-color: #f0f0f0;
}
#file-table input {
    margin-right: 8px;
}

.file-icon {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    vertical-align: middle;
}

#error-message {
    margin-top: 10px;
    color: red;
}

/* Media query for mobile devices */
@media (max-width: 750px) {
    .toolbar button {
        padding: 15px;
    }
    .toolbar button span {
        display: none;
    }
    .toolbar button img.icon {
        margin-right: 0;
    }
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.popup-window {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    max-width: 90%;
    max-height: 90%;
    overflow-y: auto;
}

.popup-button {
    margin-top: 20px;
    padding: 10px 20px;
    background-color: #a0a0a0;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.popup-button:hover {
    background-color: #808080;
}

#breadcrumb-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#status-container {
    display: flex;
    align-items: center;
    margin-right: 10px;
}

#progressbar-container {
    width: 100px;
    height: 20px;
    background-color: #ddd;
    border-radius: 5px;
    overflow: hidden;
    margin-right: 10px;
}

#progressbar {
    height: 100%;
    width: 0;
    background-color: red;
    border-radius: 5px;
    transition: width 1s, background-color 1s;
}

#memory-status {
    font-size: 14px;
    color: #333;
}

#dialogEditFile{
    width: 100%;height: 100%;border-width: 0;
}
#dialogCreateFile{
    width: 20rem;
    height: 10rem;
    border-width: 0;
    overflow: hidden;
    background: transparent;
}
#dialogCreateFile .content{
    padding: 15px;
}
#dialogCreateFile input{
    width: -webkit-fill-available;
    padding: 5px;
    border-radius: 5px;
}
dialog>div{
    border: 1px solid;border-radius: 10px;box-shadow: 0.5rem 0.5rem 1rem black;height: 100%;display: flex;flex-direction: column;background: white;
}
dialog>div>.title{
    display: flex;
    padding: 10px 15px;
}
dialog>div>.title>h4{
    flex-grow: 1;
    margin: 0;
}
dialog>div>.content{
    flex-grow: 1;overflow: hidden;
    border-top: 1px solid gray;
    border-bottom: 1px solid gray;
}
dialog>div>.content>textarea{
    width: 100%;height: 100%;border: 1px solid gray;
}
dialog>div>.buttons{
    padding: 10px;
    text-align: center;
}
dialog>div>.buttons>button{
    padding: 4px 18px;
}

.CodeMirror pre.CodeMirror-line {
    padding: 0 16px !important;
}
.CodeMirror-linenumber{
    min-width:auto !important;
}